//------------------------------------------------------------------------------
// Copyright (c) 2008 www.dnaide.com
// Licensed under the MIT (MIT-LICENSE.txt)
//------------------------------------------------------------------------------
using System;
using System.Collections;
using System.Collections.Generic;
using System.Text;
using System.Configuration;

namespace DNAide.Configuration
{
	public class HttpCompressionModuleConfig : ConfigurationElement
	{

		[ConfigurationProperty("regexCompilationMode", DefaultValue = "Compiled", IsRequired = false)]
		public RegexCompilationType RegexCompilationMode
		{
			get
			{
				return (RegexCompilationType)this["regexCompilationMode"];
			}
			set
			{
				this["regexCompilationMode"] = value;
			}
		}


		[ConfigurationProperty("enabled", DefaultValue = true, IsRequired = false)]
		public Boolean Enabled
		{
			get
			{
				return (bool)this["enabled"];
			}
			set
			{
				this["enabled"] = value;
			}
		}

		/// <summary>
		/// Collection of mimetypes and rules
		/// </summary>
		[ConfigurationProperty("mimeTypes", IsRequired = true, IsDefaultCollection = true)]
		public HttpCompressionModuleMimeTypeConfigCollection MimeTypes
		{
			get
			{
				return (HttpCompressionModuleMimeTypeConfigCollection)this["mimeTypes"];
			}
		}

	}

}
